<template>
	<view class="">
		<web-view  :src="urltext">
		</web-view>
	</view>
</template>

<script>
	export default {
		data() {
			return {
				urltext: ''
			}
		},
		onLoad(options) {
			let data = JSON.parse(decodeURIComponent(options.msg));
			this.urltext = data.url2
			// #ifdef APP-PLUS
			//右侧添加关闭按钮，点击右侧按钮直接关闭回到项目页面中
			 const pages = getCurrentPages()
			 const page = pages[pages.length - 1];
			 const currentWebview = page.$getAppWebview()
			 currentWebview.setStyle({
			 	titleNView: {
			 		buttons: [{
			 			float: 'right',
			 			type: 'close',
			 			onclick: function() {
			 				uni.switchTab({
			 					url:'/pages/homepage'
			 				})
			 			}
			 		}]
			 	}
			 })
			// #endif
			// 传入需要跳转的链接 使用web-view标签进行跳转
		}
	}
</script>
<style lang="scss">
	.head_Fixed_to {
		position: fixed;
		top: 0;
		left: 0;
		width: 100%;
		background-color: #fff;
		z-index: 201000;
	}
	.yuan {
		background-color: #3478f5;
		border-radius: 50%;
		width: 80rpx;
		height: 80rpx;
		text-align: center;
		line-height: 80rpx;
		color: #fff;
		position: fixed;
		bottom: 500rpx;
		right: 30rpx;
	}
</style>